using System.Windows.Forms;
using OhioState.AssetManaged;


namespace OhioState.Controls.AssetMgr
{
    partial class AssetManagerControl
    {
        /// <summary>
        /// Required designer variable.
        /// </summary>
        private System.ComponentModel.IContainer components = null;

        /// <summary>
        /// Clean up any resources being used.
        /// </summary>
        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
        protected override void Dispose(bool disposing)
        {
            //
            // THIS IS NOT COMPONENT DESIGNER GENERATED
            //   |
            //   v
            //
            if (disposing)
            {
                //
                // Clean up our events
                //
                AssetManager.Instance.AssetAdded -= assetManAddItemEvent;
                AssetManager.Instance.AssetRemoved -= assetManRemoveItemEvent;

                foreach (DataGridViewRow row in dataGridView.Rows)
                {
                    IAssetManaged obj = (IAssetManaged)row.Cells["DataColumn"].Value;
                    if (obj != null)
                    {
                        //
                        // Remove event handler call back to redraw the preview of the object
                        //
                        IAssetManagedHandler changed = (IAssetManagedHandler)row.Cells["EventHandlerColumn"].Value;
                        if (changed != null)
                            obj.RemoveChangedEventHandler(changed);
                    }
                }
            }
            //
            // TO HERE
            //


            if (disposing && (components != null))
            {
                components.Dispose();
            }

            base.Dispose(disposing);
        }

        #region Component Designer generated code

        /// <summary>
        /// Required method for Designer support - do not modify 
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.dataGridView = new System.Windows.Forms.DataGridView();
            this.PreviewColumn = new System.Windows.Forms.DataGridViewImageColumn();
            this.NameColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
            this.DataColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
            this.EventHandlerColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
            ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
            this.SuspendLayout();
            // 
            // dataGridView
            // 
            this.dataGridView.AllowUserToAddRows = false;
            this.dataGridView.AllowUserToDeleteRows = false;
            this.dataGridView.AllowUserToResizeColumns = false;
            this.dataGridView.AllowUserToResizeRows = false;
            this.dataGridView.CellBorderStyle = System.Windows.Forms.DataGridViewCellBorderStyle.SingleVertical;
            this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
            this.dataGridView.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
            this.PreviewColumn,
            this.NameColumn,
            this.DataColumn,
            this.EventHandlerColumn});
            this.dataGridView.Dock = System.Windows.Forms.DockStyle.Fill;
            this.dataGridView.EditMode = System.Windows.Forms.DataGridViewEditMode.EditProgrammatically;
            this.dataGridView.Location = new System.Drawing.Point(0, 0);
            this.dataGridView.Name = "dataGridView";
            this.dataGridView.RowHeadersVisible = false;
            this.dataGridView.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
            this.dataGridView.RowTemplate.Height = 24;
            this.dataGridView.RowTemplate.Resizable = System.Windows.Forms.DataGridViewTriState.False;
            this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
            this.dataGridView.Size = new System.Drawing.Size(93, 40);
            this.dataGridView.TabIndex = 4;
            this.dataGridView.KeyDown += new System.Windows.Forms.KeyEventHandler(this.dataGridView_KeyDown);
            this.dataGridView.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView_CellDoubleClick);
            this.dataGridView.CellEndEdit += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView_CellEndEdit);
            this.dataGridView.KeyUp += new System.Windows.Forms.KeyEventHandler(this.dataGridView_KeyUp);
            this.dataGridView.SelectionChanged += new System.EventHandler(this.dataGridView_SelectionChanged);
            // 
            // PreviewColumn
            // 
            this.PreviewColumn.HeaderText = "Preview";
            this.PreviewColumn.MinimumWidth = 50;
            this.PreviewColumn.Name = "PreviewColumn";
            this.PreviewColumn.Width = 50;
            // 
            // NameColumn
            // 
            this.NameColumn.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill;
            this.NameColumn.HeaderText = "Name";
            this.NameColumn.Name = "NameColumn";
            // 
            // DataColumn
            // 
            this.DataColumn.HeaderText = "Data";
            this.DataColumn.Name = "DataColumn";
            this.DataColumn.Visible = false;
            // 
            // EventHandlerColumn
            // 
            this.EventHandlerColumn.HeaderText = "EventHander";
            this.EventHandlerColumn.Name = "EventHandlerColumn";
            this.EventHandlerColumn.Visible = false;
            // 
            // AssetManagerControl
            // 
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.Controls.Add(this.dataGridView);
            this.MinimumSize = new System.Drawing.Size(93, 40);
            this.Name = "AssetManagerControl";
            this.Size = new System.Drawing.Size(93, 40);
            ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
            this.ResumeLayout(false);

        }

        #endregion

        private System.Windows.Forms.DataGridView dataGridView;
        private DataGridViewImageColumn PreviewColumn;
        private DataGridViewTextBoxColumn NameColumn;
        private DataGridViewTextBoxColumn DataColumn;
        private DataGridViewTextBoxColumn EventHandlerColumn;
    }
}
